package com.jming.yygh.order.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.jming.yygh.model.order.OrderInfo;
import com.jming.yygh.vo.order.OrderCountQueryVo;
import com.jming.yygh.vo.order.OrderQueryVo;

import java.util.Map;

/**
 * @author jming
 * @version 0.0.1
 * @date 2021/05/14
 */
public interface OrderService extends IService<OrderInfo> {

    /**
     * 根据日期Id和病人id查询保存订单信息
     *
     * @param scheduleId
     * @param patientId
     * @return Result
     */
    Long saveOrder(String scheduleId, Long patientId);

    /**
     * 根据订单id查询订单详细信息
     *
     * @param orderId
     * @return Result
     */
    OrderInfo getOrder(String orderId);

    /**
     * 订单列表信息(条件查询带分页)
     *
     * @return Result
     */
    IPage<OrderInfo> selectPage(Page<OrderInfo> orderInfoPage, OrderQueryVo orderQueryVo);

    /**
     * 订单详情
     * @param orderId
     * @return
     */
    Map<String,Object> show(Long orderId);

    /**
     * 取消预约
     * @param orderId
     * @return Result
     */
    Boolean cnncelOrder(Long orderId);

    /**
     * 就诊通知
     */
    void patientTips();

    /**
     * 预约统计
     */
    Map<String, Object> getCountMap(OrderCountQueryVo orderCountQueryVo);

}
